import React, { lazy, Suspense } from 'react'
import { BrowserRouter } from 'react-router-dom';
// import AppRouter from './router/index';
import './App.css';
import Header from './components/Header'
import Footer from './components/Footer'
import Loading from '../src/components/Loading'
const AppRouter = lazy(() => import('./router/index'))
function App() {
  return (
    <div>
      <BrowserRouter>
        <Suspense fallback={<Loading />}>
          <Header />
          <AppRouter />
          <Footer />
        </Suspense>
      </BrowserRouter>
    </div>
  );
}

export default App;
